import com.Portal.pojo.GoodVo;
import com.Portal.service.SearchService;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.test.context.junit4.SpringRunner;

import java.io.IOException;
import java.util.List;

@RunWith(SpringRunner.class)
@SpringBootTest(classes = com.Portal.PortalApplication.class)
public class test {

    @Autowired
    private SearchService searchService;
    @Test
    public void EsTest() throws IOException {
        List<GoodVo> list = searchService.GoodsList("中国移动联通电信", 1, 10);
        System.out.println("结果是："+list);
    }
}
